#ifndef FILEOPS_H
#define FILEOPS_H

#define MAX_COURSES 100
#define MAX_LENGTH 100

typedef struct {
    char courseID[MAX_LENGTH];
    char courseName[MAX_LENGTH];
    char teacherName[MAX_LENGTH];
    char courseTime[MAX_LENGTH];
    char courseLocation[MAX_LENGTH];
} Course;

// 从文件中读取课程数据
int readCoursesFromFile(Course courses[], int *numCourses);

// 保存课程数据到文件中
int saveCoursesToFile(Course courses[], int numCourses);

#endif // FILEOPS_H
